export type uploadFileParams = {
  chunkNumber: number;
  chunkSize: number;
  currentChunkSize: number;
  totalChunks: number;
  totalSize: number;
  fileName: string;
  md5: string;
  file: File | Blob;
  busiType: string;
  cursorId?: string;
  ctlgId?: string;

  unitNo?: string;
  bizCode?: string;
};

export type getTempAttachmentParams = {
  cursorId: string;
};

export type getAttachListParams = {
  busiIds: string;
  fileName?: string;
  fileType?: string;
  tag?: string;
  unitNo?: string;
  orgNo?: string;
  projCode?: string;
  bizCode?: string;
};

export type attachDataRes = {
  fileId: string; // 文件标识
  fileName: string; // 文件名称
  fileFormat: string; // 文件类型
  createTime: Date; // 上传时间
  fileSize: string; // 文件大小 kb
  originFileSize: number;
  typeId: string; // 文件类型标识
  typeName: string; // 文件类型名称
  busiId: string; // 业务标识
  createId: string; // 用户标识
  uploadName: string; // 上传人
  remark: string; // 备注
  status: number; // 附件状态，是否保存
  tag?: string;
  label?: string[]; // 附件标签
};

export type attachListDataRes = {
  cursorId: string; // 临时会话标识
  data: object[];
  previewFileType?: string[];
  fileBlackList?: string;
  fileWhiteList?: string;
  specialChars?: string;
};

export type downloadFileParams = {
  fileId: string; // 多个逗号隔开
  fileTitle?: string;
};

export type createZipParams = {
  busiIds?: string;
  tag?: string;
  orgNo?: string;
  projCode?: string;
  unitNo?: string;
};

export type getZipDownloadInfoParams = {
  id: string;
};

export type tableAttachSaveRemarkParams = {
  fileId: string;
  remark: string;
};

export type attachLabelSaveParams = {
  fileId: string;
  label: string[];
};

export type getDownLoadHistoryParams = {
  fileId: string;
};

export type downLoadHistoryRes = {
  userName: string; // 下载人
  createId: string; // 下载人标识
  createTime: Date; // 下载日期
  title: string; // 文件名称
  fileName: string; // 文件名称带后缀
  fileFormat: string; // 文件类型
  size: string; // 文件大小转换为 KB
  fileSize: number; // 文件大小未转换
  storeName: string; // 文件库名称
  typeName: string; // 文件类型名称
};

export type attachDeleteParams = {
  fileIds: string;
  cursorId: string;
};

export type attachSaveParams = {
  cursorId: string;
  busiId?: string;
  unitNo?: string;
  orgNo?: string;
  projCode?: string;
  tag?: string;
};

export type getPreviewUrlParams = {
  fileId: string;
};
